import { ReactNode } from "react"

//路由
export interface RouterType {
    path?: string,
    from?: string,
    children?: RouterType[],
    element?: JSX.Element,
    to?: string,
    name?: string,
}

export interface routerType {
    path: string,
    element: JSX.Element,
    children?: routerType[]
}

//登录
export interface loginDataType {
    username: string,
    password: string
}


// 第三方登录
export interface giteeLogin {
    code: string
}

//注册
export interface registerDataType {
    username: string,
    password: string,
    okPassword: string,
}

//用户信息
export interface UserInfoType {
    title: ReactNode
    id: number,
    name: string,
    password: string,
    username: string,
    img: string,
    sehnfen?:string
}

export interface StoreType {
    userInfo: UserInfoType | {}
}

export interface ActionType {
    type: string,
    data?: any
}


// Store state
export interface StoreInitStateType {
    groupList: any
    liveList: any
    consultList: any
    brokerList: any
    orderList: any
    housingList: any
    pageList: any
    visitList: any
    userList: any
    searchList: any
    menuList: any
    userInfo: UserInfoType,
    role:string,
    totalRouter: RouterType[],
    routerChildren: RouterType[],
}

export interface StoreStateType {
    FileReducer: any
    ArticleReducer: StoreInitStateType
    PublicReducer: StoreInitStateType
}

// table
export interface ColumsType {
    title?:string,
    width?:number
    dataIndex?:string,
    key?:string,
    fixed?:any,
    render?:any
}





// 房源管理
export interface HousingType {
    id:number
}



// 团购管理
export interface GroupType {
    id:number
}

// 订单管理
export interface OrderType {
    id:number
}



// 订单管理
export interface BrokerType {
    id:number
}

// 咨询管理
export interface ConsultType {
    id:number
}


// 直播管理
export interface LiveType {
    id:number
}